home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / Apps / ScreenSavers / BackSpaceViews / WordsView.BackModule / wraps.c < prev    next >
C/C++ Source or Header  |  1995-06-12  |  7KB  |  182 lines

  1. /* wraps.c generated from wraps.psw
  2.    by unix pswrap V1.009  Wed Apr 19 17:50:24 PDT 1989
  3.  */
  4.  
  5. #include <dpsclient/dpsfriends.h>
  6. #include <string.h>
  7.  
  8. #line 1 "wraps.psw"
  9. #line 10 "wraps.c"
  10. void PSdostuff(const char *word, float x1, float y1, float x2, float y2, float x3, float y3, float red, float green, float blue)
  11. {
  12.   typedef struct {
  13.     unsigned char tokenType;
  14.     unsigned char sizeFlag;
  15.     unsigned short topLevelCount;
  16.     unsigned long nBytes;
  17.  
  18.     DPSBinObjGeneric obj0;
  19.     DPSBinObjGeneric obj1;
  20.     DPSBinObjReal obj2;
  21.     DPSBinObjReal obj3;
  22.     DPSBinObjGeneric obj4;
  23.     DPSBinObjGeneric obj5;
  24.     DPSBinObjGeneric obj6;
  25.     DPSBinObjGeneric obj7;
  26.     DPSBinObjGeneric obj8;
  27.     DPSBinObjReal obj9;
  28.     DPSBinObjReal obj10;
  29.     DPSBinObjGeneric obj11;
  30.     DPSBinObjGeneric obj12;
  31.     DPSBinObjGeneric obj13;
  32.     DPSBinObjReal obj14;
  33.     DPSBinObjReal obj15;
  34.     DPSBinObjReal obj16;
  35.     DPSBinObjGeneric obj17;
  36.     DPSBinObjReal obj18;
  37.     DPSBinObjReal obj19;
  38.     DPSBinObjGeneric obj20;
  39.     DPSBinObjGeneric obj21;
  40.     DPSBinObjGeneric obj22;
  41.     } _dpsQ;
  42.   static const _dpsQ _dpsStat = {
  43.     DPS_DEF_TOKENTYPE, 0, 23, 192,
  44.     {DPS_LITERAL|DPS_INT, 0, 0, 1},
  45.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 150},    /* setgray */
  46.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: x1 */
  47.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: y1 */
  48.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 107},    /* moveto */
  49.     {DPS_LITERAL|DPS_STRING, 0, 0, 184},    /* param word */
  50.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 160},    /* show */
  51.     {DPS_LITERAL|DPS_INT, 0, 0, 0},
  52.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 150},    /* setgray */
  53.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: x2 */
  54.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: y2 */
  55.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 107},    /* moveto */
  56.     {DPS_LITERAL|DPS_STRING, 0, 0, 184},    /* param word */
  57.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 160},    /* show */
  58.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: red */
  59.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: green */
  60.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: blue */
  61.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 157},    /* setrgbcolor */
  62.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: x3 */
  63.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: y3 */
  64.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 107},    /* moveto */
  65.     {DPS_LITERAL|DPS_STRING, 0, 0, 184},    /* param word */
  66.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 160},    /* show */
  67.     }; /* _dpsQ */
  68.   _dpsQ _dpsF;    /* local copy  */
  69.   register DPSContext _dpsCurCtxt = DPSPrivCurrentContext();
  70.   char pad[3];
  71.   register DPSBinObjRec *_dpsP = (DPSBinObjRec *)&_dpsF.obj0;
  72.   register int _dps_offset = 184;
  73.   _dpsF = _dpsStat;    /* assign automatic variable */
  74.  
  75.   _dpsP[5].length =
  76.   _dpsP[12].length =
  77.   _dpsP[21].length = strlen(word);
  78.   _dpsP[2].val.realVal = x1;
  79.   _dpsP[3].val.realVal = y1;
  80.   _dpsP[9].val.realVal = x2;
  81.   _dpsP[10].val.realVal = y2;
  82.   _dpsP[18].val.realVal = x3;
  83.   _dpsP[19].val.realVal = y3;
  84.   _dpsP[14].val.realVal = red;
  85.   _dpsP[15].val.realVal = green;
  86.   _dpsP[16].val.realVal = blue;
  87.   _dpsP[21].val.stringVal = _dps_offset;
  88.   _dps_offset += (_dpsP[21].length + 3) & ~3;
  89.   _dpsP[12].val.stringVal = _dps_offset;
  90.   _dps_offset += (_dpsP[12].length + 3) & ~3;
  91.   _dpsP[5].val.stringVal = _dps_offset;
  92.   _dps_offset += (_dpsP[5].length + 3) & ~3;
  93.  
  94.   _dpsF.nBytes = _dps_offset+8;
  95.   DPSBinObjSeqWrite(_dpsCurCtxt,(char *) &_dpsF,192);
  96.   DPSWriteStringChars(_dpsCurCtxt, (char *)word, _dpsP[21].length);
  97.   DPSWriteStringChars(_dpsCurCtxt, (char *)pad, ~(_dpsP[21].length + 3) & 3);
  98.   DPSWriteStringChars(_dpsCurCtxt, (char *)word, _dpsP[12].length);
  99.   DPSWriteStringChars(_dpsCurCtxt, (char *)pad, ~(_dpsP[12].length + 3) & 3);
  100.   DPSWriteStringChars(_dpsCurCtxt, (char *)word, _dpsP[5].length);
  101.   DPSWriteStringChars(_dpsCurCtxt, (char *)pad, ~(_dpsP[5].length + 3) & 3);
  102.   if (0) *pad = 0;    /* quiets compiler warnings */
  103. }
  104. #line 13 "wraps.psw"
  105.  
  106. #line 107 "wraps.c"
  107. void PSdostuffnowhite(const char *word, float x1, float y1, float x2, float y2, float x3, float y3, float red, float green, float blue)
  108. {
  109.   typedef struct {
  110.     unsigned char tokenType;
  111.     unsigned char sizeFlag;
  112.     unsigned short topLevelCount;
  113.     unsigned long nBytes;
  114.  
  115.     DPSBinObjGeneric obj0;
  116.     DPSBinObjGeneric obj1;
  117.     DPSBinObjReal obj2;
  118.     DPSBinObjReal obj3;
  119.     DPSBinObjGeneric obj4;
  120.     DPSBinObjGeneric obj5;
  121.     DPSBinObjGeneric obj6;
  122.     DPSBinObjReal obj7;
  123.     DPSBinObjReal obj8;
  124.     DPSBinObjReal obj9;
  125.     DPSBinObjGeneric obj10;
  126.     DPSBinObjReal obj11;
  127.     DPSBinObjReal obj12;
  128.     DPSBinObjGeneric obj13;
  129.     DPSBinObjGeneric obj14;
  130.     DPSBinObjGeneric obj15;
  131.     } _dpsQ;
  132.   static const _dpsQ _dpsStat = {
  133.     DPS_DEF_TOKENTYPE, 0, 16, 136,
  134.     {DPS_LITERAL|DPS_INT, 0, 0, 0},
  135.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 150},    /* setgray */
  136.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: x2 */
  137.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: y2 */
  138.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 107},    /* moveto */
  139.     {DPS_LITERAL|DPS_STRING, 0, 0, 128},    /* param word */
  140.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 160},    /* show */
  141.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: red */
  142.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: green */
  143.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: blue */
  144.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 157},    /* setrgbcolor */
  145.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: x3 */
  146.     {DPS_LITERAL|DPS_REAL, 0, 0, 0},    /* param: y3 */
  147.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 107},    /* moveto */
  148.     {DPS_LITERAL|DPS_STRING, 0, 0, 128},    /* param word */
  149.     {DPS_EXEC|DPS_NAME, 0, DPSSYSNAME, 160},    /* show */
  150.     }; /* _dpsQ */
  151.   _dpsQ _dpsF;    /* local copy  */
  152.   register DPSContext _dpsCurCtxt = DPSPrivCurrentContext();
  153.   char pad[3];
  154.   register DPSBinObjRec *_dpsP = (DPSBinObjRec *)&_dpsF.obj0;
  155.   register int _dps_offset = 128;
  156.   _dpsF = _dpsStat;    /* assign automatic variable */
  157.  
  158.   _dpsP[5].length =
  159.   _dpsP[14].length = strlen(word);
  160.   _dpsP[2].val.realVal = x2;
  161.   _dpsP[3].val.realVal = y2;
  162.   _dpsP[11].val.realVal = x3;
  163.   _dpsP[12].val.realVal = y3;
  164.   _dpsP[7].val.realVal = red;
  165.   _dpsP[8].val.realVal = green;
  166.   _dpsP[9].val.realVal = blue;
  167.   _dpsP[14].val.stringVal = _dps_offset;
  168.   _dps_offset += (_dpsP[14].length + 3) & ~3;
  169.   _dpsP[5].val.stringVal = _dps_offset;
  170.   _dps_offset += (_dpsP[5].length + 3) & ~3;
  171.  
  172.   _dpsF.nBytes = _dps_offset+8;
  173.   DPSBinObjSeqWrite(_dpsCurCtxt,(char *) &_dpsF,136);
  174.   DPSWriteStringChars(_dpsCurCtxt, (char *)word, _dpsP[14].length);
  175.   DPSWriteStringChars(_dpsCurCtxt, (char *)pad, ~(_dpsP[14].length + 3) & 3);
  176.   DPSWriteStringChars(_dpsCurCtxt, (char *)word, _dpsP[5].length);
  177.   DPSWriteStringChars(_dpsCurCtxt, (char *)pad, ~(_dpsP[5].length + 3) & 3);
  178.   if (0) *pad = 0;    /* quiets compiler warnings */
  179. }
  180. #line 22 "wraps.psw"
  181.  
  182.